home *** CD-ROM | disk | FTP | other *** search
Text File | 1995-12-04 | 2.9 KB | 61 lines | [TEXT/SPM ] |
- /*
- For those of you about to dive into the code, I salute you ;-)
-
- The IC pascal application was relatively easy to port to C; Peter & Quinn's
- code is simple and straight forward. And since C and Pascal are similar,
- the port went very quickly.
-
- Understanding how the app works is another story, but a brilliant one.
-
- The IC app has a modular design; the windows, IC prefs, etc., are controlled
- using resources; this make the app relatively easy to extend to handle
- new dialogs for IC prefs.
-
- Each IC window has an associated WHAT resource which describes what
- each of the user items are (the windows are actually dialogs; each element
- that a user can interact with is a user item or a control). The WHAT
- resource consists of a bunch of elements, each element contains an IC pref
- key, an OSType which describes what the item is, and some flags.
-
- Based on the type of each item, the IC app has a number of WHAT handlers;
- some for text, buttons, lists, etc. Each WHAT handler could almost be
- a standalone component in itself; they receive open, close, flush, and other
- events which allow them to handle user interaction with the interface
- element.
-
- I have included a file, Adding New Items, which describes the process for
- adding interface elements to the IC application. The benefits of having an
- application which allows for anyone to add interface items to the IC app
- are the same benefits to having a centralized prefs area; the sharing of
- an editing interface will force IC-aware apps to use the same pref setup.
-
- Take the following example. I want to add SOCKS configuration to the IC
- prefs. No problem; through my own applications I can design a pref which
- conforms to my needs. I can use it in all of my apps that use SOCKS. Now
- programmer #2 needs to add SOCKS configuration for their program, but
- my interface is not flexible enough for the items #2 needs to interface
- with. So #2 creates his own interface. What results is a centralized
- prefs database with separate prefs for each programmer or application.
- That's just what IC was supposed to prevent!
-
- By adding a SOCKS configuration to the IC app (where most people will be
- changing their prefs), both myself and #2 would tend to use the same
- prefs since the interface already exists. Maybe #2 would need to add an
- item or two, but the benefits are still better than before.
-
- I sent a message to Peter Lewis to ask him what he thought about this;
- I am still waiting for a response.
-
- However, for the next Apprentice CD I hope to develop a totally modular
- IC application that will allow for programmers to create plug-ins for handling
- the WHAT types and perhaps an interface builder for creating new IC
- windows.
-
- The down side to this is that Peter & Quinn might feel that they have lost
- ownership of the project and stop work on the IC project; if you guys are
- reading this I hope that you won't.
-
- Dave Nebinger
- dnebing@epix.net
- */
-